home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 20 / Cream of the Crop 20 (Terry Blount) (1996).iso / program / mlht02.zip / Hottea.txt < prev    next >
Text File  |  1996-07-01  |  4KB  |  165 lines

  1. Welcome to Mike Lehman's HotTEA
  2.  
  3. Documentation current for version 2.0
  4. June 26, 1996
  5.  
  6.  
  7. ----------------------------
  8.     HotTEA Statements
  9. ----------------------------
  10.  
  11.     {} indicates an optional keyword
  12.  
  13.     All statements can be preceeded by a label followed by a colon
  14.     (see some examples below)
  15.  
  16.     Comments begin with a single quote and
  17.     continue to the end of the line
  18.  
  19.     {LET} <var> = <expr>
  20.  
  21.     GOTO <label>
  22.     GO TO <label>
  23.     IF <expr> {THEN} {CALL label|GOTO label|{LET}<var>=<expr>}
  24.     
  25.     ELSE
  26.     
  27.     ENDIF
  28.     END IF
  29.  
  30.     SUB <name>
  31.     ENDSUB
  32.     END SUB
  33.  
  34. '
  35. ' these are sample comments
  36. ' the following is a sample label attached
  37. ' to the END statement
  38.  
  39. quitit:    END        
  40.  
  41.     FOR <var> = <expr> TO <expr> {STEP <expr>}
  42.     NEXT <var>
  43.  
  44.     PRINT <expr>
  45.     PRINT <expr>,<EXPR> (tabs between)
  46.     PRINT <expr>;<EXPR>    (no space between)
  47.     CALL <subname>
  48.     RETURN
  49.  
  50. **** New For V2.0 ****
  51.  
  52.     PenColor r,g,b
  53.     PenWidth n
  54.     DrawLine x1,y1,x2,y2
  55.     DrawRect l,t,w,h{,FILLED}
  56.     (These draw in PenColor with PenWidth size lines)
  57.  
  58.     SetFont <font-name>
  59.     TextColor r,g,b
  60.     DrawText <text>,x,y
  61.  
  62.     Trace {ON | OFF}
  63.     This causes the HotTEA source code to be printed
  64.     on the Java console as it executes
  65.  
  66. ----------------------------
  67.     Built-in functions:
  68. ----------------------------
  69.  
  70.     ABS(<expr>)
  71.         take absolute value
  72.  
  73.     handle = ANIMATE(l,t,w,h,url,filename,rate,numFrames,autoStart)
  74.         load (and optionally play) an animation made from
  75.         a single .GIF/.JPG image consisting of a strip of
  76.         same-sized rectangles (see teapots3.gif as an example)
  77.  
  78.     handle = IMAGE(url,file)
  79.         load an image from your server.  Note: this does
  80.         not display the image.  Use MOVE() to put it in its place
  81.  
  82.     SHOW(handle)
  83.         display an animation or an image
  84.  
  85.     HIDE(handle)
  86.         hide an animation or an image
  87.  
  88.     MOVE(handle,x,y)
  89.         move an animation or image to a new location
  90.  
  91.     START(handle)
  92.         start an animation or a sound
  93.  
  94.     STOP(handle)
  95.         stop an animation or a sound
  96.  
  97.     INT(<expr>)
  98.     LEFT(<expr>,<len-expr>)
  99.     RIGHT(<expr>,<len-expr>)
  100.     MID(<expr>,<start>,<len-expr>)
  101.  
  102.     handle = SOUND(url,file,autoStart)
  103.         load a sound from your server.  If autoStart is <> 0 then
  104.         the sound is automatically played
  105.  
  106.  
  107.     INRECT(x,y,l,t,w,h) returns non-zero if x,y in rect l,t,l+w,t+h
  108.         Used primarily in the MOUSE_CLICK subroutine to determine
  109.         if the mouse was clicked in a rectangle.
  110.  
  111.     SHOWURL(url,name)
  112.         Used only within NetScape
  113.         name can be name of frame or title of window
  114.         (use '_self' to keep using the same window or frame)
  115.         e.g. j=showurl('http://foo.html','_self')
  116.  
  117. **** New for V2.0 ****
  118.     RND()
  119.         Returns a random number between 0.0 and 1.0
  120.  
  121. ----------------------------
  122.     Operators
  123. ----------------------------
  124.     + add or string concatenate
  125.     - subtract or unary minus
  126.     * multiply
  127.     / divide
  128.     ^ take to the power
  129.     % modulo divide
  130.     ! string concatentate
  131.  
  132.     =     equals
  133.     <>    not equals
  134.     >    greater than
  135.     <    less than
  136.     >=    greater than or equal
  137.     <=    less than or equal
  138.  
  139. ----------------------------
  140.     Notes
  141. ----------------------------
  142. ALL variables are GLOBAL
  143. NO parameter passing in level 1
  144. All expressions are either number or strings
  145. dependent upon usage.
  146.  
  147. **** New for V2.0 ****
  148.     
  149. 'Virtually Real Arrays'
  150.  
  151. You can now use a[<expr>] notation.  This translates
  152. at run-time to global variable names (e.g. a[3]
  153. translates to A#3 as a variable name.  Since you can't
  154. use # in a variable name there is no way your variable
  155. names can conflict with the 'array element' names.
  156.  
  157. Multiple dimensions are allowed as are string 'subscripts'
  158. (e.g. A["MIKE"] translates to A#MIKE, and var[3][5]
  159. translates to var#3#5)
  160.  
  161.  
  162. Good LUCK and let us know what you think.
  163.  
  164. Cereus Design Corp.
  165.